// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router'
import './assets/reset.css'
Vue.config.productionTip = false
import  {path,homePage} from './js/path'
Vue.prototype._path = path;
Vue.prototype.homePage = homePage;
import  { filter } from './js/filter'
Vue.prototype._filter = filter;
import {request} from './js/request'
Vue.prototype.requestError = request;
// element-ui
import ElementUI from 'element-ui'
import 'element-ui/lib/theme-default/index.css'
Vue.use(ElementUI)
let vm = new Vue()
// $.ajax({
//   url:path + '/users/permissions',
//   type:'GET',
//   async:false,
//   success:(res)=>{
//     if(res.code == 'SUCCESS'){
//       var s = res.data.permissions;
//       Vue.prototype.permissions = res.data.permissions;
//     }else{
//       request(res,vm)
//     }

//   }
// })


// ajax
import axios from 'axios'
Vue.prototype.$http = axios
Vue.config.productionTip = false

window.bus = new Vue()

/* eslint-disable no-new */
new Vue({
  el: '#app',
  router,
  template: '<App/>',
  components: { App },

})
